<template>
  <div class="module-header">
    <span class="module-header-title">{{ title }}</span>
    <template v-if="$slots.extra">
      <slot name="extra" />
    </template>
  </div>
</template>

<script>
export default {
  props: {
    title: {
      type: String,
      default: '',
    },
  },
};
</script>

<style lang="scss" scoped>
.module-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 36px;
  margin: 10px 0;
  padding: 0 16px;
  background: #f0f7f7;
  font-size: 16px;
  color: #757E7E;
  &-title {
    display: flex;
    align-items: center;
    &::before {
      display: inline-block;
      content: '';
      width: 6px;
      height: 20px;
      margin-right: 6px;
      background: #006666;
    }
  }
}
</style>
